<%@ page pageEncoding="UTF-8"%>
<%@ taglib prefix="isperp" uri="/WEB-INF/tlds/isperp.tld"%>

<isperp:grid gridId="roleGrid" url="app/role/list"
	gridTitle="${pageTitle}" cusFormatterActions="true" cusDialogSize="big"
	cusEditUrl="app/role/edit" ondbClickRowEvent="roleGrid.edit(rowid);"
	cusDeleteUrl="app/role/delete" excelExportUrl="app/role/excelExport">

	<jsp:attribute name="toolbar">
	<isperp:toolbar id="roleToolbar">
		<isperp:button id="roleCreate" icon="icon-plus" text="新增角色"
				cssClass="nui-mainbtn" onclick="roleGrid.create();"></isperp:button>
		 		
		<isperp:button icon="icon-plus" text="配置门户" 
				onclick="isperp.openDialog({windowSize:'maximize',contentUrl:'app/portal/rolePortalConfigEdit?roleId='+roleGrid.selrow()})"></isperp:button>
	 	</isperp:toolbar>
	</jsp:attribute>

	<jsp:attribute name="searchbar">
	<table class="search-table">
		<tbody>
			<tr>
				<td align="right">名称：</td>
				<td><input type="text" field="name" op="cn">
					</td>
				<td align="right">是否有效：</td>
				<td><input type="radio" field="status" op="ne" name="group1"
						value="-1" checked="checked" />所有 <input type="radio"
						field="status" op="eq" name="group1" value="1" />是 <input
						type="radio" field="status" op="eq" name="group1" value="0" />否</td>

			</tr>
		</tbody>
	</table>
	</jsp:attribute>
	<jsp:body>
	<isperp:column name="id" title="id" hidden="true"></isperp:column>
	<isperp:column name="name" title="名称" width="120">
	</isperp:column>
	<isperp:column name="dataRange" title="数据权限" width="50"
			isFormatterFun="true"
			formatter="if(cellvalue=='1111') return '公司级';if(cellvalue=='111') return '项目级';if(cellvalue=='11') return '工单级';return '个人级';">
	</isperp:column>
	<isperp:column name="description" title="描述" width="450">
	</isperp:column>
	<isperp:column name="status" title="是否有效" width="60"
			isFormatterFun="true"
			formatter="return isperp.statusFormatter(cellvalue)">
	</isperp:column>
	 </jsp:body>
</isperp:grid>

<isperp:operate code="ORG_ROLE"></isperp:operate>

